import Vue from 'vue'
import VueRouter from 'vue-router'
import layout from '../layout/index.vue'
import routePage from './routePage'

const routes = [{
    path: '/',
    name: 'home',
    component: layout,
    children: routePage,
  },
  {
    path: '/login',
    name: 'login',
    component: () => import( /* webpackChunkName: "about" */ '@/views/login/login.vue')
  }
]

Vue.use(VueRouter)

const router = new VueRouter({
  routes
})

export default router